package com.zhan.helloworld;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @program: Rabbitmqparent
 * @author: zhanzhewan
 * @create: 2020-03-26 09:03
 **/


@Component
@RabbitListener(queues = "direct_queue2")
public class HandlerRabbit {

    @RabbitHandler
    public void teasf(String message){
        System.out.println(message);
    }
}
